package com.liuxing.javaSpringBoot.modules.test.service;

import com.liuxing.javaSpringBoot.modules.common.entity.Result;
import com.liuxing.javaSpringBoot.modules.common.entity.SearchBean;
import com.liuxing.javaSpringBoot.modules.test.entity.Student;
import org.springframework.data.domain.Page;

import java.util.List;

/**
 * Created by IntelliJ IDEA.
 * @File StudentService.java
 * @Auth liuxing
 * @Date 2021/8/20 13:30
 * @Email liuxing997@foxmail.com
 */
public interface StudentService {

    //添加、编辑学生信息
    Result<Student> editStudent(Student student);

    //删除学生信息
    Result<Object> deleteStudentById(int id);

    //根据ID查询学生信息
    Student getStudentById(int id);

    //查询所有学生信息
    List<Student> getStudents();

    //根据姓名和邮箱查询学生信息
    Student getStudentByNameAndEmail(String name,String email);

    //多条件分页查询
    Page<Student> getStudentBySearchBean(SearchBean searchBean);

    //批量插入学生信息
    Result<Object> insertStudents(List<Student> students);
}
